

const {createPool} = require("RuoLing-SQL/Index.js");

//日志log4js
const log4js = require("../core/log4js.js");
const logger = log4js.getLogger();

let config = {
   value:{
       host:"192.168.50.128",
       user:"root",
       password:"lvdi123",
       database:"ruoling_template",
       connectionLimit : 10,
   },
    log:"debug",
    log4js:log4js,
};

// debug  info
exports.MYSQL =  function (msg){
    if(msg != null){
        logger.info(msg);
    }
    return createPool(config);
}